sendProximityPresentationRequest

suspend fun sendProximityPresentationRequest(request: List<MobileCredentialRequest>, skipStatusCheck: Boolean = false): MobileCredentialResponse

This function uses the requested mobile credentials to construct and send a presentation request to the holder. This new function, replaces the old ProximityPresentationSession.requestMobileCredentials.

If the request is not valid, an exception will be thrown. Once the request has been sent, a response is expected. As per ISO/IEC 18013-5:2021, if no response is received after 300 seconds, the request will timeout and an exception will be thrown. The session will not be terminated and a new request can be sent. When the response is received, it will be decoded, verified and returned.

The verification process is performed as per ISO/IEC 18013-5:2021 specification, subsequently the credential revocation status is checked if skipStatusCheck is false and the previous verifications have succeeded.

As per ISO/IEC 18013-5:2021, a response and sessionTermination status code can be received in the same response from the holder. In this scenario the method will return the response, trigger the onTerminated callback and close the data transport session.

Return

The response as received from the holder as an instance of MobileCredentialResponse

Parameters

request

A list of requests represented as instances of MobileCredentialRequest.

skipStatusCheck

: Defines whether the revocation status check should be skipped. By default it is set to false and status check will be performed. Network requests may be performed to check revocation status.

Throws

IllegalStateException

If SDK is not engaged in a proximity presentation session.